import { Injectable } from '@angular/core';
import { UtilService } from '../util.service';
import 'rxjs/add/operator/map';
import 'rxjs/add/operator/toPromise';
// import { SERVERURL } from '../../config/config.json';

@Injectable()
export class PromotionService {

  public promotionurl: any;
  constructor(
    public utilservice: UtilService

  ) { this.promotionurl = '/api/gooditem/list' }

  /**
   * banner
   */
  public getPromotion(page, limit) {
    let url = this.promotionurl;
    let param: any=new Object();
    param.page=page;
    param.limit=limit;
    return this.utilservice.post(url,param);
  }

}
